package com.mlz.mlzmall.ui.adapter;

import android.app.Activity;
import android.widget.ImageView;
import android.widget.TextView;

import com.mlz.mlzmall.R;
import com.mlz.mlzmall.ui.adapter.base.MallHolder;
import com.mlz.mlzmall.ui.adapter.base.ShopMallAdapter;
import com.mlz.mlzmall.ui.model.PersonalModel;

import java.util.List;

/**
 * describe :
 * Created by Benny on 2016/5/12.
 * PackageName com.mlz.mall.ui.adapter.
 * ProjectName mlzMall.
 */
public class PersonalAdapter extends ShopMallAdapter<PersonalModel> {
    private List<PersonalModel> list;

    public PersonalAdapter(Activity activity, List<PersonalModel> list, int layout) {
        super(activity,list,layout);

    }

    @Override
    public void convert(MallHolder holder, PersonalModel personalModel) {
        ImageView iv=holder.getItemView(R.id.img_pic);
        iv.setImageResource(personalModel.getImg());
        holder.setText(R.id.tv_name,personalModel.getName());

    }

}
